<!DOCTYPE html>
<html lang="en">

<head>
    <#include "/jh/admin/components/meta.html" />
    <title>雅思能力测试结果核查 ${metaTitleSuffix!}</title>
    <#include "/jh/admin/components/stylesheets.html" />
</head>

<body>
    <div id="app">
        <el-container>
            <#assign menuIndex="5-1" />
            <#include "/jh/admin/components/menu.html" />
            <el-container>
                <#include "/jh/admin/components/header.html" />
                <el-main>
                    <template>
                        <p><span style="color: green">正确:${correct!0}</span> <span style="color: red">错误:${wrong!0}</span> <span style="color: gray">未作答:${miss!0}</span></p>
                        <p>${comment!''}</p>
                        <p>${mark!''}</p>
                        <el-table :data="tableData" style="width: 100%" stripe>
                            <el-table-column label="加华国际英语—雅思能力测试结果核查">
                                <el-table-column prop="id" label="题号">
                                </el-table-column>
                                <el-table-column prop="isCorrect" label="答题状态">
                                    <template slot-scope="scope">
                                        <span v-if='scope.row.isCorrect == 0' style="color: red">错误</span>
                                        <span v-if='scope.row.isCorrect == 1' style="color: green">正确</span>
                                        <span v-if='scope.row.isCorrect == 2'>未作答</span>
                                    </template>
                                </el-table-column>
                                <el-table-column prop="answer" label="填写答案">
                                </el-table-column>
                            </el-table-column>
                        </el-table>
                    </template>
                </el-main>
            </el-container>
        </el-container>
        <#include "/jh/admin/components/footer.html" />
    </div>
    <#include "/jh/admin/components/scripts.html" />
    <script src="https://cdn.bootcss.com/json5/0.5.1/json5.min.js"></script>
    <script>
    var app = new Vue({
        el: '#app',
        data: {
            tableData: []
        },
        created() {

        },
        mounted() {
            this.setCookieData()
        },
        methods: {
            //获取数据
            setCookieData() {
                const then = this;
                // axios({
                //         url: 'http://192.168.50.18:9090/jh/question/submit',
                //         method: 'get'
                //     })
                //     .then(function(response) {
                //         if (response.data.status == 200) {
                //             then.tableData = response.data;
                //             console.log(response.data);
                //         } else {
                //             console.log("获取失败了");
                //         }
                //     })
                //     .catch(function(error) {
                //         console.log(error);
                //     });
            }
        },

    })
    </script>
    <script type="text/javascript">
    app.tableData = ${items!}
    </script>
</body>

</html>